package com.atlin.project.model.vo.cds;

import com.atlin.project.model.domain.cds.ClientFile;
import lombok.Data;
import org.springframework.beans.BeanUtils;

import java.io.Serializable;
import java.util.Date;

/**
 * 示例表
 *
 * @TableName clientFile
 */
@Data
public class ClientFileVO implements Serializable {

    
    /**
     * 客户端文件ID
     */
    
    private Long id;

    /**
     * 文件元数据ID
     */
    private Long fileMetadataId;

    /**
     * 客户端标识码ID
     */
    private Long clientCodeId;

    /**
     * 文件路径
     */
    private String filePath;

    /**
     * 
     */
    private Date updatedTime;

    /**
     * 
     */
    private Date createdTime;

    /**
     * 包装类转对象
     *
     * @param clientFileVO
     * @return
     */
    public static ClientFile voToObj(ClientFileVO clientFileVO) {
        if (clientFileVO == null) {
            return null;
        }
        ClientFile clientFile = new ClientFile();
        BeanUtils.copyProperties(clientFileVO, clientFile);

        return clientFile;
    }


    /**
     * 对象转包装类
     *
     * @param clientFile
     * @return
     */
    public static ClientFileVO objToVo(ClientFile clientFile) {
        if (clientFile == null) {
            return null;
        }
        ClientFileVO clientFileVO = new ClientFileVO();
        BeanUtils.copyProperties(clientFile, clientFileVO);
        return clientFileVO;
    }

    private static final long serialVersionUID = 1L;
}